<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "https://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<meta http-equiv="X-UA-Compatible" content="IE=9"/>
<meta name="generator" content="Doxygen 1.8.20"/>
<meta name="viewport" content="width=device-width, initial-scale=1"/>
<title>The small3d library: Setting up small3d with Xcode</title>
<link href="tabs.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="jquery.js"></script>
<script type="text/javascript" src="dynsections.js"></script>
<link href="search/search.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="search/searchdata.js"></script>
<script type="text/javascript" src="search/search.js"></script>
<link href="customdoxygen.css" rel="stylesheet" type="text/css" />
</head>
<body>
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
<div id="titlearea">
<table cellspacing="0" cellpadding="0">
 <tbody>
 <tr style="height: 56px;">
  <td id="projectlogo"><img alt="Logo" src="logo_s.png"/></td>
  <td id="projectalign" style="padding-left: 0.5em;">
   <div id="projectname">The small3d library
   </div>
  </td>
 </tr>
 </tbody>
</table>
</div>
<!-- end header part -->
<!-- Generated by Doxygen 1.8.20 -->
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&amp;dn=gpl-2.0.txt GPL-v2 */
var searchBox = new SearchBox("searchBox", "search",false,'Search');
/* @license-end */
</script>
<script type="text/javascript" src="menudata.js"></script>
<script type="text/javascript" src="menu.js"></script>
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&amp;dn=gpl-2.0.txt GPL-v2 */
$(function() {
  initMenu('',true,false,'search.php','Search');
  $(document).ready(function() { init_search(); });
});
/* @license-end */</script>
<div id="main-nav"></div>
<!-- window showing the filter options -->
<div id="MSearchSelectWindow"
     onmouseover="return searchBox.OnSearchSelectShow()"
     onmouseout="return searchBox.OnSearchSelectHide()"
     onkeydown="return searchBox.OnSearchSelectKey(event)">
</div>

<!-- iframe showing the search results (closed by default) -->
<div id="MSearchResultsWindow">
<iframe src="javascript:void(0)" frameborder="0" 
        name="MSearchResults" id="MSearchResults">
</iframe>
</div>

</div><!-- top -->
<div class="PageDoc"><div class="header">
  <div class="headertitle">
<div class="title">Setting up <a class="el" href="namespacesmall3d.html">small3d</a> with Xcode </div>  </div>
</div><!--header-->
<div class="contents">
<div class="textblock"><p>On MacOS, the <a class="el" href="namespacesmall3d.html">small3d</a> unit tests and sample game can be built from the command line, just like on any other platform. However you might want to create an Xcode project, in order to use the Xcode debugger for example.</p>
<p>In this case, as a first step, instead of the <code>scripts/build.sh</code> script, the <code>deps/prapare.sh</code> has to be launched. Then, <a class="el" href="namespacesmall3d.html">small3d</a> together with its unit tests can be configured and built for Xcode as follows (execute from the main directory): </p><pre class="fragment">mkdir build
cd build
cmake .. -G"Xcode"
cmake --build .
</pre><p>The created project, <code>build/small3d.xcodeproj</code> can then be opened in Xcode.</p>
<p>There are some settings that need to be taken care of before proceeding to run and debug the unit tests though. From the Project Navigator, click on <code><a class="el" href="namespacesmall3d.html">small3d</a></code>, and then on the <code>unittests</code> target. Select <code>Build Settings</code> and scroll down to <code>User-Defined</code>. There, the <code>CONFIGURATION_BUILD_DIR</code> variable needs to be set to the <code>bin</code> directory in all cases, for example <code>/Users/me/Source/small3d/build/bin/</code>, rather than the differentiated directories it is set to by default, e.g. <code>bin/Debug</code>, <code>bin/Release</code>, etc. </p>
</div></div><!-- contents -->
</div><!-- PageDoc -->
<!-- start footer part -->
<hr class="footer"/><address class="footer"><small>
Generated by&#160;<a href="http://www.doxygen.org/index.html"><img class="footer" src="doxygen.svg" width="104" height="31" alt="doxygen"/></a> 1.8.20
</small></address>
</body>
</html>
